package com.heima.article.job;

import com.heima.article.service.HotArticlesService;
import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class ComputerHotArticleJob {
    @Autowired
    private HotArticlesService hotArticleService;

    @XxlJob("computerHotArticleJob")
    public ReturnT computerHotArticleJob(String param){
        hotArticleService.computeHotArticle();
        return ReturnT.SUCCESS;
    }
}
